package com.xian;

/**
 * @Author: yanjunfeng
 * @Description: TODO
 * @Date: Created in 下午2:56 2022/7/13
 * @Modified By:
 */

/**
 * 拿固定工资的
 */
public class SalariedEmployee extends  Employee{

    private double monthSalary;//月薪

    public double getMonthSalary() {
        return monthSalary;
    }

    public void setMonthSalary(double monthSalary) {
        this.monthSalary = monthSalary;
    }

    public SalariedEmployee(String name,int month,double monthSalary){
        //调用父类构造函数
        super(name,month);
        this.monthSalary=monthSalary;
    }

    @Override
    public double getSalary() {
       return this.monthSalary+this.getSalarybyBri();
    }
}
